<?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>
﻿<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title></title>
<meta name="keywords" content="个人博客模板,博客模板,响应式" />
<meta name="description" content="如影随形主题的个人博客模板，神秘、俏皮。" />
<!--头部开始-->
 <?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>
<link href="http://127.0.0.1/cms/cms/Template/black/css/base.css" rel="stylesheet">
<link href="http://127.0.0.1/cms/cms/Template/black/css/index.css" rel="stylesheet">
<link href="http://127.0.0.1/cms/cms/Template/black/css/media.css" rel="stylesheet">
<link href="http://127.0.0.1/cms/cms/Template/black/css/style.css" rel="stylesheet">
<meta name="viewport" content="width=device-width, minimum-scale=1.0, maximum-scale=1.0">
<!--[if lt IE 9]>
<script src="js/modernizr.js"></script>
<![endif]-->
</head>

<body>
	<div class="ibody">
		<header>
			<h1><?php echo $title;?></h1>
			<h2>我的生活像 拍了一出戏 有超多导演跟编剧</h2>
			<nav id="topnav">
				<a href="http://127.0.0.1/cms/cms/index.php">首页</a>
				<?php
	$navList = M('category')->field('cid,cname,ctitle,htmldir,is_archtml')->where('pid=0')->limit(10)->all();
	foreach($navList as $navs):
	$navs['url'] = getCateUrl($navs['is_archtml'],$navs['htmldir'],$navs['cid']);
?>
	
					<a href="http://127.0.0.1/cms/cms/index.php/Index/list/index/cid/<?php echo $navs['cid'];?>"><?php echo $navs['cname'];?></a>
				
<?php
	endforeach;
?>
			</nav>
		</header>
<!--头部结束-->
  <article>
    <h2 class="about_h"><!--您现在的位置是：<a href="/">首页</a>><a href="1/">模板分享</a>><a href="1/">个人博客模板</a>--></h2>
    <div class="index_about">
      <h2 class="c_titile"><?php echo $artInfo['title'];?></h2>
      <p class="box_c"><span class="d_time">发布时间：<?php echo date('Y-m-d',$artInfo['sendtime']);?></span><span>作者：<?php echo $artInfo['author'];?></span><span>浏览（<?php echo $artInfo['click'];?>）</span></p>
      <ul class="infos">
        <?php echo $artInfo['content'];?>
      </ul>
      <div class="keybq">
        <p><span>关键字词</span>：
        	<?php foreach ($artInfo['tags'] as $key=>$val){?>
				<?php echo $val['tagname'];?>
			<?php }?>
        </p>
      </div>
      
      <div class="otherlink">
        <h2>相关文章</h2>
        <ul>
          <?php
		$result = M()->where("category_cid=28")->join('__article__ a JOIN __category__ c ON a.category_cid=c.cid')->limit(10)->all();
		foreach($result as $field):
		$field['url'] = getStaticPath($field['is_archtml'],$field['htmldir'],$field['aid']);
?>
	
          <li><a href="<?php echo $field['url'];?>" title="<?php echo $field['title'];?>"><?php echo $field['title'];?></a></li>
          
<?php
	endforeach;
?>
        </ul>
      </div>
    </div>
  </article>
 <!--右边开始-->
 <?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>
 <aside>
    <div class="avatar"><a href="about.html"><span>关于邦</span></a></div>
    <div class="topspaceinfo">
      <h1><?php echo $title;?></h1>
      <p>我的生活像 拍了一出戏 有超多导演跟编剧</p>
    </div>
    <div class="about_c">
      <p>网名：邦 </p>
      <p>职业：PHPer </p>
      <p>籍贯：江西省-赣州市</p>
      <p>电话：18650680200</p>
      <p>邮箱：375500819@qq.com</p>
    </div>
    
    <div class="tj_news">
      <h2>
        <p class="tj_t1">最新文章</p>
      </h2>
      <ul>
      	<?php
		$result = M('article')->field('htmldir,cname,is_archtml,aid,sendtime,click,title,thumb,digest,author,category_cid')->join('__article__ a JOIN __category__ c ON a.category_cid=c.cid')->where('is_recycle=0')->order('sendtime DESC')->limit(10)->all();
		foreach($result as $v):
			//组合图片图片
			$v['thumb']  = 'http://127.0.0.1/cms/cms/'.$v['thumb'];
			$v['commnum'] = K('Comment')->findCountComment($v['aid']);
			$category = K('Category')->findCate($v['category_cid']);
			$v['category_name'] = $category['cname'];
			//生成连接地址
			$v['url'] = getStaticPath($v['is_archtml'],$v['htmldir'],$v['aid']);
			
			 
?>	
	
        	<li><a href="<?php echo $v['url'];?>"><?php echo $v['title'];?></a></li>
        
<?php
	endforeach;
?>	
      </ul>
      <h2>
        <p class="tj_t2">推荐文章</p>
      </h2>
      <ul>
      	<?php
		$result = K('article')->findSpeExp('is_recycle=0 AND attr LIKE "%推荐%"','click DESC',8);
		foreach($result as $recom):
		$recom['thumb']  = 'http://127.0.0.1/cms/cms/'.$recom['thumb'];
		$recom['commnum'] = K('Comment')->findCountComment($recom['aid']);
		//生成连接地址
		$recom['url'] = getStaticPath($recom['is_archtml'],$recom['htmldir'],$recom['aid']);
?>
		
        <li><a href="<?php echo $recom['url'];?>"><?php echo $recom['title'];?></a></li>
        
<?php
	endforeach;
?>
      </ul>
    </div>
    <div class="links">
      <h2>
        <p>友情链接</p>
      </h2>
      <ul>
      	<?php
		$result = K('flink')->showAllFlink(1,10,'sort DESC');
		foreach($result as $flink):
		$flink['url'] = 'http://'.$flink['url'];
		$flink['logo']  = 'http://127.0.0.1/cms/cms/'.$flink['logo'];
		
?>
	
        <li><a href="<?php echo $flink['url'];?>"><?php echo $flink['fname'];?></a></li>
        
<?php
	endforeach;
?>	
      </ul>
    </div>
    <div class="copyright">
      <ul>
        <p> Design by <a href="/"><?php echo $title;?></a></p>
        <p></p>
        </p>
      </ul>
    </div>
  </aside>
 <!--右边结束-->
  <script src="js/silder.js"></script>
  <div class="clear"></div>
  <!-- 清除浮动 --> 
</div>
</body>
</html>
